using System;
using System.Collections.Generic;
using System.Text;
using System.Data;
using TienTeTuong;
using log4net;
namespace TienTeTuong
{
    public class ProductDetailBUS
    {

        private ProductDetailDAO dao = new ProductDetailDAO();
        public List<CateDetailProductDTO> GetListProductDetail(string CateDetailID)
       {
           return dao.GetListProductDetail(CateDetailID);
       }
        public List<OptionDTO> GetCategoryDetailOption(string cateDetailID)
        {
            return dao.GetCategoryDetailOption(cateDetailID);
        }
        public List<ProductDetailDTO> listProductDetail()
        {
            return dao.listProductDetail();
        }

        public List<ProductDetailDTO> searchProductDetailByName(string key)
        {
            return dao.searchProductDetailByName(key);
        }
		public CateDetailProductDTO getProductDetailByID(string key)
        {
			return dao.getProductDetailByID(key);
		}
        public bool deleteProduct(string key) {
            return dao.deleteProduct(key);
        }
        public bool saveProduct(ProductDetailDTO item) {
            return dao.saveProduct(item);
        }
        public bool addProduct(ProductDetailDTO item)
        {
            return dao.addProduct(item);
        }
        public bool deleteCateDetailProductByCateDetailID(string id)
        {
            return dao.deleteCateDetailProductByCateDetailID(id);
        }
        public bool updateCateDetailProduct(string proId, string cateDtID, string quantity)
        {
            return dao.updateCateDetailProduct(proId, cateDtID, quantity);
        }
    }
}
